/**
 * 侧边模块选项特效
 */
	$(document).ready(function(){
		var one=0;
		var two=0;
		var three=0;
		var four=0;
		$("#menu-talk1head").click(function(){
			openYHYS();
			 $(this).css("color","rgba(65, 140, 144, 0.76)");
			 $("#menu-talk1").css("background-image","url('../image/02-menu-sayTopic.png')");
			 one=1;two=0;three=0;four=0;
			 $("#menu-office1head").css("color","white");
			 $("#complainthead").css("color","white");
			 $("#user-manage").css("color","white");
			 $("#menu-office1").css("background-image","url('../image/02-menu-office.png')");
	         $("#complaint").css("background-image","url('../image/02-menu-complaint.png')");
	         $("#menu-userManage").css("background-image","url('../image/02-menu-userManage.png')");
		});
		$("#menu-office1head").click(function(){
			openBX();
			 $(this).css("color","rgba(65, 140, 144, 0.76)");
			 $("#menu-office1").css("background-image","url('../image/03-makeup.png')");
			 one=0;two=1;three=0;four=0;
			 $("#menu-talk1head").css("color","white");
			 $("#complainthead").css("color","white");
			 $("#user-manage").css("color","white");
			 $("#menu-talk1").css("background-image","url('../image/03-menu-talk.png')");
	         $("#complaint").css("background-image","url('../image/02-menu-complaint.png')");
	         $("#menu-userManage").css("background-image","url('../image/02-menu-userManage.png')");
		});
		$("#complainthead").click(function(){
			openTs();
			 $(this).css("color","rgba(65, 140, 144, 0.76)");
			 $("#complaint").css("background-image","url('../image/04-plaint.png')");
			 one=0;two=0;three=1;four=0;
			 $("#menu-talk1head").css("color","white");
			 $("#menu-office1head").css("color","white");
			 $("#user-manage").css("color","white");
			 $("#menu-talk1").css("background-image","url('../image/03-menu-talk.png')");
			 $("#menu-office1").css("background-image","url('../image/02-menu-office.png')");
	         $("#menu-userManage").css("background-image","url('../image/02-menu-userManage.png')");
		});
		$("#user-manage").click(function(){
			openLogin();
			 $(this).css("color","rgba(65, 140, 144, 0.76)");
			 $("#menu-userManage").css("background-image","url('../image/05-userManage.png')");
			 one=0;two=0;three=0;four=1;
			 $("#menu-talk1head").css("color","white");
			 $("#menu-office1head").css("color","white");
			 $("#complainthead").css("color","white");
			 $("#menu-talk1").css("background-image","url('../image/03-menu-talk.png')");
			 $("#menu-office1").css("background-image","url('../image/02-menu-office.png')");
	         $("#complaint").css("background-image","url('../image/02-menu-complaint.png')");
		});

        $("#menu-talk1head").mouseenter(function(){
            $("#menu-talk1").css("background-image","url('../image/02-menu-sayTopic.png')");
            $(this).css("border-bottom","2px solid rgba(65, 140, 144, 0.76)");
            $(this).css("color","rgba(65, 140, 144, 0.76)");
            
        });
        $("#menu-talk1head").mouseleave(function(){
            if(!one==1){
                $(this).css("color","white");
                $("#menu-talk1").css("background-image","url('../image/03-menu-talk.png')");
        	}
            $(this).css("border-bottom","2px solid #303642");
            
        });
        $("#menu-office1head").mouseenter(function(){
            $("#menu-office1").css("background-image","url('../image/03-makeup.png')");
            $(this).css("border-bottom","2px solid rgba(65, 140, 144, 0.76)");
            $(this).css("color","rgba(65, 140, 144, 0.76)");
        });
        $("#menu-office1head").mouseleave(function(){
            
            if(!two==1){
            	$("#menu-office1").css("background-image","url('../image/02-menu-office.png')");
                $(this).css("color","white");
        	}
            $(this).css("border-bottom","2px solid #303642");
        });
        $("#complainthead").mouseenter(function(){
            $("#complaint").css("background-image","url('../image/04-plaint.png')");
            $(this).css("border-bottom","2px solid rgba(65, 140, 144, 0.76)");
            $(this).css("color","rgba(65, 140, 144, 0.76)");
        });
        $("#complainthead").mouseleave(function(){
            
            if(!three==1){
            	$("#complaint").css("background-image","url('../image/02-menu-complaint.png')");
                $(this).css("color","white");
        	}
            $(this).css("border-bottom","2px solid #303642");
        });
        $("#user-manage").mouseenter(function(){
            $("#menu-userManage").css("background-image","url('../image/05-userManage.png')");
            $(this).css("border-bottom","2px solid rgba(65, 140, 144, 0.76)");
            $(this).css("color","rgba(65, 140, 144, 0.76)");
        });
        $("#user-manage").mouseleave(function(){
            
            if(!four==1){
            	$("#menu-userManage").css("background-image","url('../image/02-menu-userManage.png')");
                $(this).css("color","white");
        	}
            $(this).css("border-bottom","2px solid #303642");
        });
	});